
// FirstMFCProjectView.h : interface of the CFirstMFCProjectView class
//

#pragma once


class CFirstMFCProjectView : public CView
{
protected: // create from serialization only
	CFirstMFCProjectView();
	DECLARE_DYNCREATE(CFirstMFCProjectView)

// Attributes
public:
	CFirstMFCProjectDoc* GetDocument() const;
	/************ Tiancai **************/
private:
	CPoint m_beginPoint;
	CPoint m_endPoint;
/************ Tiancai **************/

// Operations
public:
/************ Tiancai **************/
private:
	//{{AFX_MSG(FirstMFCProjectView)
	// void OnLButtonDown(UINT nFlag, CPoint point);
	//}}AFX_MSG
	// DECLARE_MESSAGE_MAP()
	void DrawLine(CPoint begin, CPoint end, COLORREF color);
/************ Tiancai **************/
// Overrides
public:
	virtual void OnDraw(CDC* pDC);  // overridden to draw this view
	virtual BOOL PreCreateWindow(CREATESTRUCT& cs);
protected:
	virtual BOOL OnPreparePrinting(CPrintInfo* pInfo);
	virtual void OnBeginPrinting(CDC* pDC, CPrintInfo* pInfo);
	virtual void OnEndPrinting(CDC* pDC, CPrintInfo* pInfo);

// Implementation
public:
	virtual ~CFirstMFCProjectView();
#ifdef _DEBUG
	virtual void AssertValid() const;
	virtual void Dump(CDumpContext& dc) const;
#endif

protected:

// Generated message map functions
protected:
	afx_msg void OnFilePrintPreview();
	afx_msg void OnRButtonUp(UINT nFlags, CPoint point);
	afx_msg void OnContextMenu(CWnd* pWnd, CPoint point);
	/************ Tiancai **************/
	afx_msg void OnLButtonDown(UINT nFlag, CPoint point);
	afx_msg void OnLButtonUp(UINT nFlag, CPoint);
	afx_msg void OnMouseMove(UINT nFlag, CPoint point);
	/************ Tiancai **************/
	DECLARE_MESSAGE_MAP()
};

#ifndef _DEBUG  // debug version in FirstMFCProjectView.cpp
inline CFirstMFCProjectDoc* CFirstMFCProjectView::GetDocument() const
   { return reinterpret_cast<CFirstMFCProjectDoc*>(m_pDocument); }
#endif

